<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ page import="java.util.List" %>
<%@ page import="cn.tedu.entity.User" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
	<div style="text-align: center;">
		<div style="font-size: 30px;font-weight: bold;">显示用户信息</div>
		<table border="=1" align="center">
			<tr>
				<th>序号1</th>
				<th>序号2</th>
				<th>id</th>
				<th>用户名</th>
				<th>密码</th>
				<th>年龄</th>
				<th>地址</th>
				<th>删除</th>
				<th>修改</th>
			</tr>
		 <%
		    //在这样的符号中可以写java代码
		    Object obj_users=request.getAttribute("suoyouyonghu");
		    List<User> users=(List<User>)obj_users;
		    for(int i=0;i<users.size();i++){
		    	User user=users.get(i);
		 %>
			<tr>
				<td><%=i+1 %></td>
				<td><%=i+1 %></td>
				<td><%=user.getId() %></td>
				<td><%=user.getName() %></td>
				<td><%=user.getPassword() %></td>
				<td><%=user.getAge() %></td>
				<td><%=user.getAddress() %></td>
				<td><a href="#">删除</a></td>
				<td><a href="#">修改</a></td>
			</tr>
		  <%} %>
		</table>	
	</div>
</body>
</html>